feat: ISC map support — the runtime reads the current corpus again - #5
Merged
Merged
Conversation
The maps corpus ships only .isc now (zero .imp files remain); the Python runtime could not parse any of it — every map call raised at line 1 (CI last ran 2026-08-20, so nobody saw it go dark). isc.py: a faithful port of the reference TypeScript parser (interscript-ts src/isc, itself mirroring the Ruby Parslet grammar) plus the converter into the engine's existing tree — engine and .imp parser untouched (OCP). Coverage measured against the full corpus: 252/289 maps convert cleanly, zero parse errors; the remaining 37 fail LOUDLY on known vocabulary gaps (function-in-result 22, etc.) under the engine's own on_unsupported contract, which now threads through load_map for conversion-time gaps too. Converter semantics worth naming: - parallel subs render to expression source; sequence/bare rules to raw regex with before/after/not_before/not_after as lookarounds (_guarded_regex) — dropping them was the Oleghovych regression, caught by the parity table - capture-bearing parallel rules degrade to ordered substitutions ahead of the capture-free parallel op (documented; the digraph- prevention shape every real map uses) - library dependencies (posix/unicode .iml) contribute aliases, harvested and re-rendered through the expression layer — no duplicated grammar; single-quoted .iml literals normalized Parity: bgnpcgn-ukr returns Anton Olehovych / Solomiia / Kyiv and bgnpcgn-deu returns Tschueß! — byte-identical with the TypeScript and Ruby runtimes (tests/test_gallery_parity.py is the gate). Bulgarian 98/98 and Greek >=200/242 embedded-test parity restored.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The Python map runtime reads the current ISC corpus again.
Why
The corpus ships only
.isc(zero.impfiles remain); the Python runtime parsed.imponly, so every map call raised at line 1 — the whole runtime was dark, unseen because CI last ran 2026-08-20. TypeScript and Ruby both parse the current format.Implementation
src/interscript/isc.py— a faithful port of the reference TypeScript parser (interscript-ts/src/isc, mirroring the Ruby Parslet grammar) + the converter into the engine's existing tree. Engine and.impparser untouched (OCP)..iml) contribute aliases, re-rendered through the existing expression layer.on_unsupportednow threads throughload_mapfor conversion-time vocabulary gaps — the engine's own raise/skip contract.Verification (measured)
Anton Olehovych/Solomiia/Kyiv,Tschueß!— byte-identical with TypeScript and Ruby.